<%--
  Created by IntelliJ IDEA.
  User: asus
  Date: 2019/9/1
  Time: 9:31
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
    <title>展示用户信息</title>
    <!--导入bootstrap框架-->
    <link href="${pageContext.request.contextPath}/css/bootstrap.min.css" rel="stylesheet">
    <link href="$${pageContext.request.contextPath}/css/index.css" rel="stylesheet">
    <script src="${pageContext.request.contextPath}/js/jquery-3.2.1.min.js"></script>
    <script src="${pageContext.request.contextPath}/js/bootstrap.min.js"></script>
    <script src="${pageContext.request.contextPath}/js/owl.carousel.min.js"></script>
    <script src="${pageContext.request.contextPath}/js/jquery.mixitup.min.js"></script>
    <script src="${pageContext.request.contextPath}/js/jquery.fancybox.min.js"></script>
    <script src="${pageContext.request.contextPath}/js/jquery.counterup.min.js"></script>
    <script src="${pageContext.request.contextPath}/js/waypoints.min.js"></script>
    <script src="${pageContext.request.contextPath}/js/jquery.magnific-popup.min.js"></script>
    <script src="${pageContext.request.contextPath}/js/countdown.js"></script>
    <script src="${pageContext.request.contextPath}/js/script.js"></script>
</head>
<style>
    .first_td {
        /*border: 1px solid;*/
        text-align: center;
        font-size: 16px;
    }
    .lt {
        text-align: center;
        margin-top: 75px;

    }

    #history{
        width: 85%;
        text-align: center;
        margin-top: 85px;
        margin-left: 130px;
    }
    #his_btn{
        float: right;
        margin-right: 200px;

    }
    #title{
        font-size: 32px;
    }
    #uls{
        margin-left: 130px;
    }
</style>
<body>
    <div>
        <div class="lt">
            <h3 id="title">历史入住用户</h3>
        </div>
            <button id="his_btn" onclick="javascript:history.back(-1);" type="button" class="btn btn-default navbar-btn" style="float: right">返回</button>
    </div>
    <div style="height: 500px">
        <table class="table table-hover" id="history">
            <tr>
                <th class="first_td">用户编号</th>
                <th class="first_td">用户姓名</th>
                <th class="first_td">身份证号</th>
                <th class="first_td">入住日期</th>
                <th class="first_td">退房日期</th>
            </tr>
            <c:forEach items="${clientList}" var="client" varStatus="vs">
                <tr>
                    <td class="first_td">${vs.count}</td>
                    <td class="first_td">${client.clientName}</td>
                    <td class="first_td">${client.clientIdcard}</td>
                    <td class="first_td">${client.clientDate}</td>
                    <td class="first_td">${client.clientEndtime}</td>
                </tr>
            </c:forEach>
        </table>
    </div>
</div>
</body>
<nav aria-label="Page navigation">
    <ul class="pagination" id="uls">
        <li>
            <a href="#" aria-label="Previous">
                <span aria-hidden="true">&laquo;</span>
            </a>
        </li>
        <c:forEach begin="1" end="${pageInfo.pages}" var="i">
            <c:if test="${pageInfo.pageNum==i}" >
                <li  class="active"><a href=${pageContext.request.contextPath}/client/findHis?currentPage=${i}&rows=5>${i}</a></li>
            </c:if>
            <c:if test="${pageInfo.pageNum!=i}" >
                <li><a href=${pageContext.request.contextPath}/client/findHis?currentPage=${i}&rows=5>${i}</a></li>
            </c:if>
        </c:forEach>
        <li>
            <a href="#" aria-label="Next">
                <span aria-hidden="true">&raquo;</span>
            </a>
        </li>
        <span><font size="5">共有${pageInfo.endRow}位客户,共${pageInfo.pages}页</font></span>
    </ul>
</nav>
</html>
